package com.listener;

import java.io.File;

/**
 * @ClassName: EmailNotificationListener
 * @Description:
 * @Author Fly
 * @Date 2022/12/19 11:38
 */
public class EmailNotificationListener implements EventListener {

    private String email;

    public EmailNotificationListener(String email) {
        this.email = email;
    }

    @Override
    public void update(String eventType, File file) {
        System.out.println(" Email to " + email +": Someone has performed " + eventType + " operation with the following file:" + file.getName());
    }
}
